package com.heitian.ssm.service.impl;

import com.heitian.ssm.dao.CallRecordDao;
import com.heitian.ssm.model.CallRecord;
import com.heitian.ssm.service.CallRecordService;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;
import java.util.List;

@Service
@Transactional(rollbackFor = Exception.class)
public class CallRecordServiceImpl implements CallRecordService{

    @Resource
    private CallRecordDao callRecordDao;

    public Integer save(CallRecord callRecord) {
        return callRecordDao.saveCallRecord(callRecord);
    }

    public Integer update(CallRecord callRecord) {
        return null;
    }

    public Integer delete(String id) {
        return null;
    }

    public CallRecord getCallRecord(String place){
        return callRecordDao.getCallRecord(place);
    }

    public List<CallRecord> getCallRecordList(String place,String startTime,String endTime){ return callRecordDao.getCallRecordList(place,startTime,endTime); }

	public int answer(CallRecord callRecord) {
		return callRecordDao.answer(callRecord);
	}
}
